﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml;
using Javavaj.iHunter;

namespace Javavaj.iHunter.Core
{
    public enum EditItemType
    {
        /// <summary>
        /// 单行字符串
        /// </summary>
        SingleLineText,
            
        /// <summary>
        /// 多行字符串
        /// </summary>
        MultiLineText,

        /// <summary>
        /// 文件路径
        /// </summary>
        FilePath,

        /// <summary>
        /// 不需要回复，只显示对应的字符串给用户
        /// </summary>
        StaticText
    }

    public class EditReplyEventArgs : EventArgs
    {
        //hc:
        //插件向主程序获得回复输入的事件参数
        //tag是一个用于频道自定义的字符串，主程序不改变它
        //replyPairs是<string,EditItemType>数组
        private IChannel channel;

        public IChannel Channel
        {
            get { return channel; }
        }
        private IMessage source;
        private string tag;
        private KeyValuePair<string, EditItemType>[] replyItems;

        public EditReplyEventArgs(IChannel channel, IMessage source, KeyValuePair<string, EditItemType>[] replyItems, string tag)
            : base()
        {
            this.channel = channel;
            this.source = source;
            this.tag = tag;
            this.replyItems = replyItems;
        }

        public IMessage Source
        {
            get
            {
                return source;
            }
        }

        public string Tag
        {
            get
            {
                return tag;
            }
        }
        public KeyValuePair<string, EditItemType>[] ReplyItems
        {
            get
            {
                return replyItems;
            }
        }
    }

    public delegate void EditReplyEventHandler(object sender, EditReplyEventArgs e);

}